import { createRouter, createWebHistory } from "vue-router";
const routes: any = [
  {
    path: "/",
    name: "auth",
    meta: {
      title: "授权",
    },
    component: () => import("@/views/Auth.vue"),
  },
  {
    path: "/chat",
    name: "chat",
    meta: {
      title: "问答",
    },
    component: () => import("@/views/Home.vue"),
  },
  {
    path: "/404",
    name: "404",
    meta: {
      title: "404",
    },
    component: () => import("@/views/NoPermission.vue"),
  },
];

const router = createRouter({
  history: createWebHistory(),
  routes,
  scrollBehavior: () => ({ left: 0, top: 0 }),
});
export default router;
